﻿using SharpErp.UI.Common;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using SharpErp.UI.Common.Attribute;

namespace SharpErp.UI.BusinessDocument
{
    [Menu(Module = MenuModule.BusinessOrder, MenuName = "订单")]
    public partial class UIBusinessOrderForm : BaseTabForm 
    {
        public UIBusinessOrderForm()
        {
            InitializeComponent();
            this.dataGridViewX1.Rows.Add(6);
        }

        private void buttonAddColumn_Click(object sender, EventArgs e)
        {
            if (sender == buttonAddColumn)
            {
                dataGridViewX1.Rows.Add();
            }
            else if(sender == buttonDeleteColumn)
            {
               if(dataGridViewX1.CurrentRow != null) dataGridViewX1.Rows.Remove(dataGridViewX1.CurrentRow);
            }
        }

        private void btnAddCusto_Click(object sender, EventArgs e)
        {
            new CustomInfoForm().ShowDialog();
        }

        private void buttonClose_Click(object sender, EventArgs e)
        {
            this.Close();
        }

        private void butonSave_Click(object sender, EventArgs e)
        {
            new PayForm().ShowDialog();
        }
    }
}
